//
//  storyBoardViewController.m
//  bu
//
//  Created by 何林晋 on 14-1-16.
//  Copyright (c) 2014年 fanchuang. All rights reserved.
//

#import "storyBoardViewController.h"
#import "MMProgressHUD.h"
//#import "MMProgressHUDOverlayView.h"

@interface storyBoardViewController ()

@end

@implementation storyBoardViewController
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation{
    return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown);
}
- (BOOL)shouldAutorotate{
    return YES;
}

- (NSUInteger)supportedInterfaceOrientations{
    return UIInterfaceOrientationMaskAllButUpsideDown;
}
- (void)viewDidLoad
{
    [super viewDidLoad];
	// Do any additional setup after loading the view, typically from a nib.
}


- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (IBAction)hudButton:(id)sender {
    [MMProgressHUD setPresentationStyle:MMProgressHUDPresentationStyleExpand];
    [MMProgressHUD showWithTitle:@"Animation" status:@"Expand"];
    
    double delayInSeconds = 2.5;
    dispatch_time_t popTime = dispatch_time(DISPATCH_TIME_NOW, delayInSeconds * NSEC_PER_SEC);
    dispatch_after(popTime, dispatch_get_main_queue(), ^(void){
        [MMProgressHUD dismissWithSuccess:@" " title:@" "];
    });
}
@end
